package com.cheng.example.book.deepintojvm.chapter02.j02;


import java.util.ArrayList;
import java.util.List;

/*
 * description:
 *
 * -Xms20m -Xmx20m -XX:+HeapDumpOnOutOfMemoryError
 *
 * @author 程帅
 * @Date: 2020/11/27 14:41
 */
public class Client241 {

    static class OOMObject {
    }

    public static void main(String[] args) {
        List<OOMObject> list = new ArrayList<OOMObject>();
        while (true) {
            list.add(new OOMObject());
        }
    }

}
